package thinkingJava.chapter13;

import java.util.Scanner;
/**
 * BufferedReader--BufferedStream--StreamReader()
 * Scanner sc.nextInt sc.nextFloat sc.nextDouble (except nextChar)
 * @author Administrator
 *
 */
public class ScannerDelimiter {
	public static void main(String[] args) {
		Scanner sc = new Scanner("18, 42, 78, 89, 42");
		sc.useDelimiter("\\s*,\\s*");
		System.out.println(sc.delimiter());
		while (sc.hasNext()) {
			System.out.println(sc.nextInt());
		}
	}
}
